
export function copyText(text: any) {
    const oInput = ref<any>()
    if (document.getElementById('copyInput')) {
        oInput.value = document.getElementById('copyInput')
    } else {
        oInput.value = document.createElement('input')
    }
    oInput.value.value = text
    oInput.value.id = 'copyInput'
    oInput.value.className = 'copy-input'
    document.body.appendChild(oInput.value)
    oInput.value.select() // 选择对象;
    document.execCommand('Copy') // 执行浏览器复制命令
    ElMessage.success('复制成功！');
}